package com.uchiha.nova.core.feign;

import com.uchiha.nova.core.model.vo.ChinaOrgCodeVO;
import com.uchiha.nova.core.tool.constant.ApplicationConstant;
import com.uchiha.nova.core.tool.constant.NovaCRUDMethodConstant;
import com.uchiha.nova.core.model.dto.ChinaOrgCodeDTO;
import com.uchiha.nova.core.tool.api.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;
import java.util.Map;

@FeignClient(value = ApplicationConstant.WEB_SERVICE, configuration = FeignConfiguration.class)
public interface ChinaOrgCodeFeignService {

    String BASE = "/chinaOrgCode";

    @GetMapping(BASE + "/tree")
    R tree(@RequestParam(defaultValue = "370600000000") Long id);

    @GetMapping(BASE + "/tree/station")
    R treeStation(@RequestParam(defaultValue = "370600000000") Long id);

    /**
     *详情
     */
    @PostMapping(BASE+ NovaCRUDMethodConstant.NOVA_WEB_GETONE)
    R detail(@RequestBody ChinaOrgCodeDTO chinaOrgCodeDTO);

}